package com.isunland.managesystem.ui;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import com.isunland.managesystem.entity.LeaseMainList;

/**
 * 开发公司: 北京信普达系统工程有限公司
 * 开发人员: wangyanan
 * 创建时间: 2016/12/16 15:44
 */

public class LeaseOrderUpdateActivity extends SingleFragmentActivity {
  private LeaseMainList mItem;

  @Override public void onCreate(Bundle arg0) {
    mItem = (LeaseMainList) getIntent().getSerializableExtra(LeaseOrderUpdateFragment.EXTRA_DETAIL);
    super.onCreate(arg0);
  }

  @Override protected Fragment createFragment() {
    return LeaseOrderUpdateFragment.newInstance(mItem);
  }

  public static void newInstance(android.support.v4.app.Fragment fragment, Activity context,
      LeaseMainList item, int requestCode) {
    if (fragment == null || context == null) return;
    Intent intent = new Intent(context, LeaseOrderUpdateActivity.class);
    intent.putExtra(LeaseOrderUpdateFragment.EXTRA_DETAIL, item);
    fragment.startActivityForResult(intent, requestCode);
  }
}


